package xyz.molzhao.performance;

import java.util.concurrent.ForkJoinPool;

public class CommonPoolSize {
    public static void main(String[] args) {
        // CPU核心数 - 8
        System.out.println(Runtime.getRuntime().availableProcessors());
        // 当前线程数 - 0
        System.out.println(ForkJoinPool.commonPool().getPoolSize());
        // 最大线程数 - 7
        System.out.println(ForkJoinPool.commonPool().getParallelism());
    }
}
